<template>
	<view class="agreement">
		<view class="nav_bar" style="background-color: rgba(255, 255, 255, 1);">
			<uni-nav-bar color="#333" left-icon="left" title="" :border='false' :fixed="true"
				background-color="transparent" @clickLeft="$util.back()"></uni-nav-bar>
		</view>
		<view class="nav_box"></view>
		<view class="rich-text">
			<rich-text :nodes="data"></rich-text>
		</view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				data: '',
			}
		},
		methods: {
			getData(type){
				this.$post(`/index/policy?type=${type}`).then(res=>{
					this.data = res.data[type]
				})
			},
		},
		onLoad(option) {
			this.getData(option.type)
		}
	}
</script>

<style lang="less" scoped>
	.rich-text {
		padding: 32rpx;
	}
	
	.agreement {
		
	}
</style>
